<template>
  <div class="myTable">
    <!-- 数据列表 -->
    <el-table
      :data="companys"
      element-loading-text="给我一点时间"
      fit
      highlight-current-row
      style="width: 100%"
      border
    >
      <el-table-column align="center" label="试题编号" width="70">
        <template slot-scope="scope">
          <span>{{ scope.row.id }}</span>
        </template>
      </el-table-column>

      <el-table-column align="center" label="学科">
        <template slot-scope="scope">
          <span>{{ scope.row.number }}</span>
        </template>
      </el-table-column>

      <el-table-column align="center" label="目录">
        <template slot-scope="scope">
          <span>{{ scope.row.shortName }}</span>
        </template>
      </el-table-column>

      <el-table-column label="题型">
        <template slot-scope="scope">
          <span>{{ scope.row.tags }}</span>
        </template>
      </el-table-column>

      <el-table-column align="center" label="题干">
        <template slot-scope="scope">
          <span>{{ scope.row.creatorID }}</span>
        </template>
      </el-table-column>

      <el-table-column align="center" label="录入时间">
        <template slot-scope="scope">
          <span>{{ scope.row.addDate }}</span>
        </template>
      </el-table-column>

      <el-table-column align="center" label="难度">
        <template slot-scope="scope">
          <span>{{ scope.row.remarks.substring(0, 3) }}</span>
        </template>
      </el-table-column>

      <el-table-column align="center" label="录入人" width="80">
        <template slot-scope="scope">
          <span v-if="scope.row.state == 1">启用</span>
          <span v-else>禁用</span>
        </template>
      </el-table-column>

      <el-table-column align="center" label="审核状态">
        <template slot-scope="scope">
          <span>{{ scope.row.remarks.substring(0, 3) }}</span>
        </template>
      </el-table-column>

      <el-table-column align="center" label="审核意见">
        <template slot-scope="scope">
          <span>{{ scope.row.remarks.substring(0, 3) }}</span>
        </template>
      </el-table-column>

      <el-table-column align="center" label="审核人">
        <template slot-scope="scope">
          <span>{{ scope.row.remarks.substring(0, 3) }}</span>
        </template>
      </el-table-column>

      <el-table-column align="center" label="发布状态">
        <template slot-scope="scope">
          <span>{{ scope.row.remarks.substring(0, 3) }}</span>
        </template>
      </el-table-column>

      <el-table-column
        align="center"
        label="操作"
        width="280"
        class-name="small-padding fixed-width"
      >
        <template slot-scope="scope">
          <el-button type="text" size="mini">{{scope.row.id}}</el-button>
          <el-button type="text" size="mini">审核</el-button>
          <el-button type="text" size="mini">修改</el-button>
          <el-button type="text" size="mini">上架</el-button>
          <el-button type="text" size="mini">删除</el-button>
        </template>
      </el-table-column>
    </el-table>

    <div class="pagination">
      <div class="pages">
        <el-pagination
          align="right"
          background
          :current-page="Number(5)"
          :page-size="Number(form.pagesize)"
          :page-sizes="[10, 20, 30, 50]"
          layout="sizes, prev, pager, next, jumper"
        ></el-pagination>
      </div>
    </div>
  </div>
</template>

<script>
export default {
  data() {
    return {
      companys: [],
      form: [],
    };
  },
};
</script>

<style>
</style>